<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=<?=$this->config->item('charset');?>">
	<title>用户登录_爱厨房</title>

	<meta name="description" content="{$seo_description}" />
	<meta name="keywords" content="{$seo_keywords}" />
	<link href="<?=base_url('static/css/global.css')?>" rel="stylesheet" type="text/css" media="screen">
	<link href="<?=base_url('static/css/login.css')?>" rel="stylesheet" type="text/css" media="screen">
	<script src="<?=path_res('static/js/jquery.js')?>"></script>
	<script src="<?=path_res('static/js/functions.js')?>"></script>
</head>
<body>

<? $this->load->view('header'); ?>
<div id="main" class="clearfix">

<input id="needcolselead" type="hidden" value="OK">
<div class="bgrf clearfix">
			<div class="nsoine">
				<div class="thplat">
					<h2>登录</h2>
					<h3>使用以下账号快速登录</h3>
					<div class="rplate">
						<a class="btnrqq mrl left" href="<?=site_url('user/api_connect/QQ')?>" title="QQ账号登录" target="_blank">QQ账号登录</a>
						<a class="btnrsina mrl left" href="<?=site_url('user/api_connect/Sina')?>" title="新浪微博登录" target="_blank">新浪微博登录</a>
					</div>
				</div>
				<div class="logbox">
					<h3>使用邮箱账号登录</h3>
					<div class="logone">						
						<form action="<?=site_url('user/login')?>" method="post" onsubmit="return login();">
							<div class="itm clearfix">
								<label>邮箱</label>
								<div class="iput"><input id="email" name="email" value="" class="retext" type="text"></div>
								<span class="lowrong mll">请输入邮箱</span>       
							</div>
							<div class="itm mtl mb28 clearfix">
								<label>密码</label>
								<div class="iput">
									<input id="password" name="password" onblur="checkpassword()" value="" class="retext" maxlength="20" type="password">
									<span class="jizme mtm"><input name="remember" type="checkbox" value="1" id="remember" checked="checked" class="czl"> 记住我&nbsp;<font class="flin">|</font>&nbsp;<a href="<?php echo site_url('user/forgot_password')?>">忘记密码</a></span>
								</div>
								<span></span> 
							</div>	
							<?php if ($show_captcha): ?>
							<div class="itm clearfix">
								<div class="yanma ml70">
									<input id="captcha" name="captcha" value="" onblur="checkcode()" class="yzmtext" maxlength="8" type="text" placeholder="输入验证码">  <img id='codeshow' src="<?=site_url('ajax/captcha_image')?>" onclick="javascript:this.src='<?=site_url('ajax/captcha_image')?>?'+Math.floor(Math.random()*99)" style="cursor:pointer;border-radius:4px 4px 4px 4px" title="看不清? 换一张"/> 
								</div>
							</div>
							<div class="iisi"><font color="red">校验码错误</font></div>
					        <?php endif; ?>					
							<div class="iloo">								
								<button id="doLogin" type="submit" class="btnlo fwb">登录</button><span class="plm">没有账号，<a href="<?php echo site_url('user/register')?>">从这里注册</a></span>
							</div>
							<input type="hidden" id="forward" value="/" />
						</form>
					</div>
				</div>
			</div>
		</div>


</div>
<script type="text/javascript">
$(document).ready(function(){
	$("#email").focus();
});

function checkcode(){
    var code=$.trim($('#captcha').val());  
    $.post("/uajax/ajaxcode",{code: code}, function(flag){
        if(1==flag){
            hidedesc($('#captcha'));
        }else{
            showdesc($('#captcha'));
        }
    });
}
</script>
<script src="<?=path_res('static/js/signup.js')?>"></script>
<? $this->load->view('footer'); ?>